package com.mall.quartz.util;

import com.mall.quartz.domain.SysJob;
import org.quartz.DisallowConcurrentExecution;
import org.quartz.JobExecutionContext;

/**
 * 定时任务处理（禁止并发执行）
 * Created by zhonglin on 2020/4/8.
 */
@DisallowConcurrentExecution
public class QuartzDisallowConcurrentExecution
    extends AbstractQuartzJob {

  @Override
  protected void doExecute(JobExecutionContext context,
                           SysJob sysJob)
      throws Exception {

    JobInvokeUtil.invokeMethod(sysJob);
  }

}
